<template>
	<!-- 热点资讯 -->
	<view class="">
		<view class="zixun-box" v-for="(zixunItem,index) in newsList" :key="index" @click="newsDetail(zixunItem)">
			<view class="zixun-list flex-js-ac" >
				<view class="zixun-list-box flex-j-sb-as-fc">
					<text class="line-2 text-28-161616">{{zixunItem.title}}</text>
					<view class="zixun-bottom-zz">
						<text class="text-18-A4A4A4">{{zixunItem.source}}</text>
						<text class="text-18-A4A4A4">{{zixunItem.createTime}}</text>
					</view>
				</view>
				<!-- <u-lazy-load class="news-r-img" :image="image" height="142"></u-lazy-load> -->
				<u-lazy-load class="news-r-img" :image="getImg(zixunItem.titlePic)" threshold="300"></u-lazy-load>
			</view>
			<view class="mg-lr-25" style="height: 1rpx;background-color: #E5E5E5;"></view>
			
		</view>
	</view>


</template>

<script>
	export default {
		props: {
			newsList:{
				type:Array,
				default:[]
			}
		},
		data() {
			return {
				image: "https://tse3-mm.cn.bing.net/th/id/OIP.NZRmMpqidLDt68839mVztAHaJQ?w=137&h=180&c=7&o=5&pid=1.7",
				loadingImg: '/static/uView/loading.png',
				errorImg: '/static/uView/load_error.png'
			}
		},
		methods: {
			newsDetail(e){
				this.$emit("toDetail",e)
			}
		}
	}
</script>

<style>
	.zixun-box {
		margin-top: 10rpx;
		
	}

	.zixun-list {
		margin-bottom: 20rpx;
	}

	.zixun-list-box {
		height: 122rpx;
		margin-left: 25rpx;
		margin-right: 25rpx;
		flex: 1;
	}

	.news-r-img {
		height: 142rpx;
		width: 235rpx;
		margin-right: 25rpx;
	}

	.zixun-bottom-zz>text:nth-of-type(1) {
		margin-right: 40rpx;
		opacity: 0.5;
	}

	.zixun-bottom-zz>text:nth-of-type(2) {
		opacity: 0.5;
	}
</style>
